package com.example.bili.controller;

import com.example.bili.entity.History;
import com.example.bili.service.HistoryService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/htry")
public class HtyController {

    @Resource
    private HistoryService historyService;

    @PostMapping("/addHtry")
    public Object addHtry(@RequestBody History htry){
        return historyService.addHtry(htry);
    }

    @GetMapping("/delHtry/{id}")
    public Object delHtry(@PathVariable int id){
        return historyService.delHtry(id);
    }
}
